package com.lims.landInfo.model;

import javax.persistence.*;

import org.hibernate.annotations.GenericGenerator;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

import javacommon.base.*;

import cn.org.rapid_framework.util.*;
/**
 * @author zzh
 * @version 1.0
 * @since 1.0
 */@Entity
@Table(name = "LIMS_Information")
public class Information extends BaseEntity implements java.io.Serializable{
	private static final long serialVersionUID = 5454155825314635342L;
	//date formats
	public static final String FORMAT_LAND_DATE = DATE_FORMAT;
	public static final String FORMAT_CREATE_DATE = DATE_FORMAT;
	
	//columns START
    /**
     * objid       db_column: OBJID 
     */ 	
	private java.lang.String objid;
    /**
     * sno       db_column: sno 
     */ 	
	private java.lang.Integer sno;
    /**
     * landno       db_column: landno 
     */ 	
	private java.lang.String landno;
    /**
     * landDeedNo       db_column: landDeedNo 
     */ 	
	private java.lang.String landDeedNo;
    /**
     * houseCardNo       db_column: houseCardNo 
     */ 	
	private java.lang.String houseCardNo;
    /**
     * houseOwner       db_column: houseOwner 
     */ 	
	private java.lang.String houseOwner;
    /**
     * corp       db_column: corp 
     */ 	
	private java.lang.String corp;
    /**
     * east       db_column: east 
     */ 	
	private java.lang.String east;
    /**
     * south       db_column: south 
     */ 	
	private java.lang.String south;
    /**
     * west       db_column: west 
     */ 	
	private java.lang.String west;
    /**
     * north       db_column: north 
     */ 	
	private java.lang.String north;
    /**
     * landLevel       db_column: landLevel 
     */ 	
	private java.lang.String landLevel;
    /**
     * sellAmount       db_column: sellAmount 
     */ 	
	private java.lang.Double sellAmount;
    /**
     * sellExample       db_column: sellExample 
     */ 	
	private java.lang.String sellExample;
    /**
     * marketPrice       db_column: marketPrice 
     */ 	
	
	private java.lang.Double marketPrice;
    /**
     * marketExample       db_column: marketExample 
     */ 	
	private java.lang.String marketExample;
    /**
     * describe       db_column: describe 
     */ 	
	private java.lang.String describe;
    /**
     * landDate       db_column: landDate 
     */ 	
	private java.util.Date landDate;
    /**
     * createDate       db_column: createDate 
     */ 	
	private java.util.Date createDate;
	//columns END


	public Information(){
	}

	public Information(
		java.lang.String objid
	){
		this.objid = objid;
	}

	public void setObjid(java.lang.String value) {
		this.objid = value;
	}
	
	@Id @GeneratedValue(generator="custom-id")
	@GenericGenerator(name="custom-id", strategy = "uuid")//unique = true, 
	@Column(name = "OBJID", nullable = false, insertable = true, updatable = true, length = 32)
	public java.lang.String getObjid() {
		return this.objid;
	}
	
	@Column(name = "sno", unique = false, nullable = true, insertable = true, updatable = true, length = 10)
	public java.lang.Integer getSno() {
		return this.sno;
	}
	
	public void setSno(java.lang.Integer value) {
		this.sno = value;
	}
	
	@Column(name = "landno", unique = false, nullable = true, insertable = true, updatable = true, length = 20)
	public java.lang.String getLandno() {
		return this.landno;
	}
	
	public void setLandno(java.lang.String value) {
		this.landno = value;
	}
	
	@Column(name = "landDeedNo", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getLandDeedNo() {
		return this.landDeedNo;
	}
	
	public void setLandDeedNo(java.lang.String value) {
		this.landDeedNo = value;
	}
	
	@Column(name = "houseCardNo", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getHouseCardNo() {
		return this.houseCardNo;
	}
	
	public void setHouseCardNo(java.lang.String value) {
		this.houseCardNo = value;
	}
	
	@Column(name = "houseOwner", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getHouseOwner() {
		return this.houseOwner;
	}
	
	public void setHouseOwner(java.lang.String value) {
		this.houseOwner = value;
	}
	
	@Column(name = "corp", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getCorp() {
		return this.corp;
	}
	
	public void setCorp(java.lang.String value) {
		this.corp = value;
	}
	
	@Column(name = "east", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getEast() {
		return this.east;
	}
	
	public void setEast(java.lang.String value) {
		this.east = value;
	}
	
	@Column(name = "south", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getSouth() {
		return this.south;
	}
	
	public void setSouth(java.lang.String value) {
		this.south = value;
	}
	
	@Column(name = "west", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getWest() {
		return this.west;
	}
	
	public void setWest(java.lang.String value) {
		this.west = value;
	}
	
	@Column(name = "north", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getNorth() {
		return this.north;
	}
	
	public void setNorth(java.lang.String value) {
		this.north = value;
	}
	
	@Column(name = "landLevel", unique = false, nullable = true, insertable = true, updatable = true, length = 50)
	public java.lang.String getLandLevel() {
		return this.landLevel;
	}
	
	public void setLandLevel(java.lang.String value) {
		this.landLevel = value;
	}
	
	@Column(name = "sellAmount", unique = false, nullable = true, insertable = true, updatable = true, length = 22)
	public java.lang.Double getSellAmount() {
		return this.sellAmount;
	}
	
	public void setSellAmount(java.lang.Double value) {
		this.sellAmount = value;
	}
	
	@Column(name = "sellExample", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getSellExample() {
		return this.sellExample;
	}
	
	public void setSellExample(java.lang.String value) {
		this.sellExample = value;
	}
	
	@Column(name = "marketPrice", unique = false, nullable = true, insertable = true, updatable = true, length = 22)
	public java.lang.Double getMarketPrice() {
		return this.marketPrice;
	}
	
	public void setMarketPrice(java.lang.Double value) {
		this.marketPrice = value;
	}
	
	@Column(name = "marketExample", unique = false, nullable = true, insertable = true, updatable = true, length = 100)
	public java.lang.String getMarketExample() {
		return this.marketExample;
	}
	
	public void setMarketExample(java.lang.String value) {
		this.marketExample = value;
	}
	
	@Column(name = "describe", unique = false, nullable = true, insertable = true, updatable = true, length = 200)
	public java.lang.String getDescribe() {
		return this.describe;
	}
	
	public void setDescribe(java.lang.String value) {
		this.describe = value;
	}
	
	@Transient
	public String getLandDateString() {
		return DateConvertUtils.format(getLandDate(), FORMAT_LAND_DATE);
	}
	public void setLandDateString(String value) {
		setLandDate(DateConvertUtils.parse(value, FORMAT_LAND_DATE,java.util.Date.class));
	}
	
	@Column(name = "landDate", unique = false, nullable = true, insertable = true, updatable = true, length = 0)
	public java.util.Date getLandDate() {
		return this.landDate;
	}
	
	public void setLandDate(java.util.Date value) {
		this.landDate = value;
	}
	
	@Transient
	public String getCreateDateString() {
		return DateConvertUtils.format(getCreateDate(), FORMAT_CREATE_DATE);
	}
	public void setCreateDateString(String value) {
		setCreateDate(DateConvertUtils.parse(value, FORMAT_CREATE_DATE,java.util.Date.class));
	}
	
	@Column(name = "createDate", unique = false, nullable = true, insertable = true, updatable = true, length = 0)
	public java.util.Date getCreateDate() {
		return this.createDate;
	}
	
	public void setCreateDate(java.util.Date value) {
		this.createDate = value;
	}
	

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("Objid",getObjid())
			.append("Sno",getSno())
			.append("Landno",getLandno())
			.append("LandDeedNo",getLandDeedNo())
			.append("HouseCardNo",getHouseCardNo())
			.append("HouseOwner",getHouseOwner())
			.append("Corp",getCorp())
			.append("East",getEast())
			.append("South",getSouth())
			.append("West",getWest())
			.append("North",getNorth())
			.append("LandLevel",getLandLevel())
			.append("SellAmount",getSellAmount())
			.append("SellExample",getSellExample())
			.append("MarketPrice",getMarketPrice())
			.append("MarketExample",getMarketExample())
			.append("Describe",getDescribe())
			.append("LandDate",getLandDate())
			.append("CreateDate",getCreateDate())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getObjid())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof Information == false) return false;
		if(this == obj) return true;
		Information other = (Information)obj;
		return new EqualsBuilder()
			.append(getObjid(),other.getObjid())
			.isEquals();
	}
}

